package model;

import java.util.Observable;

public class Methods extends Observable {
	
	private double result;
	
	public Methods () {
		
	}

	public void Add(double value) {
		setResult(getResult() + value);
	}
	
	public double getResult() {
		return result;
	}

	public void setResult(double result) {
		this.result = result;
		setChanged(); // Tell the display that the value has changed
	}
	
	public void setResult(String value) {
		setResult(Double.parseDouble(value));
	}
}
